﻿@using FC.Web.Models

<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>@ViewBag.Title - FeelingCoder 一个神奇的网站</title>
    <link href="~/Content/bootstrap.min.css" rel="stylesheet" type="text/css" />
    <link href="~/Content/Site.css" rel="stylesheet" type="text/css" />
    @RenderSection("Style", false)
</head>
<body>
    <header>
        <nav class="navbar navbar-default navbar-fixed-top" style="height:60px;">
            <div class="container" style="margin-top:3px;">
                <div class="navbar-header">
                    <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
                        <span class="icon-bar"></span>
                        <span class="icon-bar"></span>
                        <span class="icon-bar"></span>
                    </button>
                    @Html.ActionLink("FeelingsCoder", "Index", "Home", new { area = "" }, new { @class = "navbar-brand" })
                </div>
                <div class="navbar-collapse collapse">
                    <ul class="nav navbar-nav">
                        @*<li><a href="#"><span class=""></span>试题集</a></li>*@
                    </ul>
                    <ul class="nav navbar-nav navbar-right">
                        @if (Session["User"] == null)
                        {
                            <li><a href="~/Account/Login" class="btn btn-default" style="margin-right: 10px; padding: 10px; margin-top:5px; width:100px"><span class="glyphicon glyphicon-user" style="margin-right: 5px;"></span> 登录 </a></li>
                            <li><a href="~/Account/Register" class="btn btn-default" style="padding: 10px; margin-top:5px; width:100px;"><span class="glyphicon glyphicon-plus" style="margin-right: 5px;"></span> 注册</a></li>
                        }
                        else
                        {
                            if ((Session["User"] as User).UserName == "admin")
                            {
                                <li><a href="~/Manager"><span class=""></span>管理</a></li>
                            }
                            <li><a href="~/Contests"><span class=""></span>试题集</a></li>
                            @*<li><a href="~/Blog"><span class=""></span>博客</a></li>
                                <li><a href="~/Code"><span class=""></span>代码库</a></li>*@
                            <li><a href="~/User"><span class="glyphicon glyphicon-user"></span> @(((User)Session["User"]).UserName)</a></li>
                            <li><a href="~/Account/Logout">注销</a></li>
                        }
                    </ul>
                </div>
            </div>
        </nav>
        @RenderSection("Header", false)
    </header>
    <div class="container">
        @RenderBody()
    </div>

    <footer class="container">
        <hr />
        <p>&copy; @DateTime.Now.Year - My ASP.NET Application</p>
    </footer>

    <script src="~/Scripts/jquery-3.1.1.min.js"></script>
    <script src="~/Scripts/jquery.validate.min.js"></script>
    <script src="~/Scripts/jquery.validate.unobtrusive.min.js"></script>
    <script src="~/Scripts/jquery.unobtrusive-ajax.min.js"></script>
    <script src="~/Scripts/bootstrap.min.js"></script>
    @RenderSection("Script", false)

</body>
</html>